package contains

import "strings"

func Contains(elems []string, v string) bool {
	if len(elems) == 0 || len(v) == 0 {
		return false
	}

	for _, s := range elems {
		if len(s) == 0 {
			continue
		}
		if v == s {
			return true
		}
	}
	return false
}

func StrContainsElement(elems []string, v string) bool {
	if len(elems) == 0 || len(v) == 0 {
		return false
	}

	for _, s := range elems {
		if len(s) == 0 {
			continue
		}
		if strings.Contains(v, s) {
			return true
		}
	}
	return false
}
